pldm_over_mctp_sources = [
  'pldm_over_mctp.cpp',
  'pldm_over_mctp_standard.cpp',
  'pldm_over_mctp_emulex.cpp',
]

pldm_over_mctp_headers = [
  'pldm_over_mctp.h',
  'pldm_over_mctp_standard.h',
  'pldm_over_mctp_emulex.h',
]

libpldm_over_mctp = shared_library(
  'dev_pldm_over_mctp',
  pldm_over_mctp_sources,
  include_directories: dev_inc_dir,
  dependencies: [libmcpp_deps, libmctp_dep],
  install: true,
  install_dir: lib_dir,
)

libpldm_over_mctp_dep = declare_dependency(
  link_with: libpldm_over_mctp,
  include_directories: [dev_inc_dir],
  dependencies: [libmcpp_deps, libmctp_dep],
)

install_headers(pldm_over_mctp_headers, install_dir: install_inc_dir / 'pldm_over_mctp')

if build_tests and meson_build
  custom_target(
    'copy_dev_pldm_over_mctp',
    output: 'copy_dev_pldm_over_mctp',
    command: ['cp', libpldm_over_mctp.full_path(), lib_dir],
    depends: libpldm_over_mctp,
    build_by_default: true,
  )
endif